<template>
    <div>
      {{interval$}}
    </div>
</template>

<script>
  import {interval} from 'rxjs'
  import {filter} from 'rxjs/operators'
  import {webSocket} from 'rxjs/webSocket'
  export default {
    name: "base-02",
    subscriptions(){
      return {
        interval$:interval(1000).pipe(filter(x=>x%2===0))
      }
    },
    mounted(){
      interval(1000).pipe(filter(x=> false)).subscribe(
        x => console.log('sub',x)
      )
    }
  }
</script>

<style scoped>

</style>
